import request from '@/utils/request'

let api = {};

api.cas = ()=>{
    return request({
        url:"/api/member/system/casRouter",
        method:"post"
    });
}

api.list = (params = null) => {
    return request({
        url: "/api/member/system/listRouters",
        method: "post",
        data: params
    });
}

api.delete = (ids) => {
    return request({
        url: "/api/member/system/softdeleteRouter",
        method: "post",
        data: ids
    });
}

api.add = (params) => {
    return request({
        url: "/api/member/system/addRouter",
        method: "post",
        data: params
    });
}

api.edit = (params) => {
    return request({
        url: "/api/member/system/editRouter",
        method: "post",
        data: params
    });
}

api.getParent = (id)=>{
    return request({
        method:"post",
        url:"/api/member/system/getRouterParent/"+id
    });
}

export default api;